import { createStore, ModuleTree, Store, StoreOptions } from 'vuex'
import { store as UserStore, State as UserState } from './modules/user';
const storeOption: StoreOptions<RootState> = {
    modules: {
        UserStore
    }
}


export type RootState = {
    user: UserState;
};

const store: Store<RootState> = createStore(storeOption);

export function useStore() {
    return store;
}
export default store